package com.momo.gateway.feign;

import com.momo.gateway.common.JSONResult;
import com.momo.gateway.entity.RedisUser;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Service;

/**
 * Created by Kagome on 2019/4/24.
 */
@Service
@Slf4j
public class TebsiteVisitFeignImpl {
    @Autowired
    private TebsiteVisitFeign tebsiteVisitFeign;

    @Async("threadPoolTaskExecutor")
    public JSONResult visitPeopleToRedis() {
        RedisUser redisUser=new RedisUser();
        redisUser.setRedisUserKey("aaa");
        JSONResult jsonResult = tebsiteVisitFeign.visitPeopleToRedis(redisUser);
        return jsonResult;
    }
}
